package global

import (
	"github.com/smartwalle/alipay/v3"
	"log"
)

func init() {
	var err error

	if AliClient, err = alipay.New(kAppId, kPrivateKey, false); err != nil {
		log.Println("初始化支付宝失败", err)
		return
	}

	if err = AliClient.LoadAliPayPublicKey(PublicKey); err != nil {
		log.Println("加载公钥发生错误", err)
		return
	}
}
